<HTML><HEAD><TITLE>attached_suspensions(+Trigger, -SuspensionList)</TITLE>
</HEAD><BODY>[ <A HREF="index.html">Advanced Control and Suspensions</A> | <A HREF="../../index.html">Reference Manual</A> | <A HREF="../../fullindex.html">Alphabetic Index</A> ]
<H1>attached_suspensions(+Trigger, -SuspensionList)</H1>
Retrieves a list of all suspensions attached to the symbolic trigger Trigger.
<DL>
<DT><EM>Trigger</EM></DT>
<DD>An atom
</DD>
<DT><EM>SuspensionList</EM></DT>
<DD>Variable or List.
</DD>
</DL>
<H2>Description</H2>
    Retrieves all suspensions (dead or live) attached to the trigger Trigger,
    and returns them in SuspensionList.
<P>
    Note that you can use sort/2 to eliminate duplicates, and
    is_suspension/1 to filter out dead suspensions.

<H3>Modes and Determinism</H3><UL>
<LI>attached_suspensions(+, -) is det
</UL>
<H2>Examples</H2>
<PRE>
?- suspend(true, 3, trigger(hello)), attached_suspensions(hello, S).
S = ['SUSP-_207-susp']
Delayed goals:
        true
Yes (0.00s cpu)
</PRE>
<H2>See Also</H2>
<A HREF="../../kernel/suspensions/suspensions-1.html">suspensions / 1</A>, <A HREF="../../kernel/suspensions/suspensions-2.html">suspensions / 2</A>, <A HREF="../../kernel/suspensions/subcall-2.html">subcall / 2</A>, <A HREF="../../kernel/suspensions/get_suspension_data-3.html">get_suspension_data / 3</A>, <A HREF="../../kernel/termcomp/sort-2.html">sort / 2</A>, <A HREF="../../kernel/typetest/is_suspension-1.html">is_suspension / 1</A>
</BODY></HTML>
